package project1;

/**
 *  @author Andrew O'Connor
 *  COSC 603
 *  Project 1
 */
public class RepeatedWord {
    private String word;
    private int lineNumber;

    /**
     *
     * @param _word repeated word
     * @param _lineNumber line number where repeat can be found
     */
    public RepeatedWord(String _word, int _lineNumber) {
        word = _word;
        lineNumber = _lineNumber;
    }

    /**
     *
     * @return repeat as string
     */
    public String toString() {
        return "Repeated word on line " + lineNumber + ": " + word;
    }
}
